package com.example.zhongbiao;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.view.animation.Animation;
import android.view.animation.AnimationUtils;
import android.widget.ImageView;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        initxuanzhuan();
    }
    private void initxuanzhuan()
    {
        ImageView imageView1 = findViewById(R.id.img_shizhen);
        ImageView imageView2 = findViewById(R.id.img_fenzhen);
        ImageView imageView3 = findViewById(R.id.img_miaozhen);
        Animation animation1 = AnimationUtils.loadAnimation(this,R.anim.xuanzhuan_shi);
        Animation animation2 = AnimationUtils.loadAnimation(this,R.anim.xuanzhuan_fen);
        Animation animation3 = AnimationUtils.loadAnimation(this,R.anim.xuanzhuan_miao);
        imageView1.setAnimation(animation1);
        imageView2.setAnimation(animation2);
        imageView3.setAnimation(animation3);
    }
}